<template>
  <div class="detail">
    <div class="list">
      <div class="item" v-for="(item, idx) in list" :key="idx">
        <div class="item-title" >
          <i class="">1</i>
          {{ item.title }}
        </div>
        <div v-if="item.children" class="item-children">
          <detailList :list="item.children"></detailList>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: 'detailList',
  props: {
    list: Array
  }
}
</script>

<style lang="scss">
.detail {
  .list {
    .item {
    .item-title {
      line-height: 40px;
      padding: 0 15px;
      font-size: 24px;
      border-bottom: 1px solid #999;
      i {
        display: inline-block;
        line-height:90%;
        width: 5px;
        background-color: aqua;
        border-top-right-radius: 7px;
        border-bottom-right-radius: 10px;
        color: transparent;
      }
    }
    .item-children {
      padding: 0 30px;
    }
    }
  }
}
</style>
